<SCRIPT LANGUAGE="JavaScript">  
    function validation()
    {
        var temp="";
        temp=document.getElementById('JobSlip');
        if( temp.value=='' )
        {
            alert('Please provide the payment slip');
            return false;             
        }     
    }
    
    function open_win(id)
    {
        window.open('../../jobs/view/'+id,"_blank","toolbar=no, location=yes, directories=no, status=no, menubar=no, scrollbars=yes, resizable=no, copyhistory=yes, top=100, left=100, width=930, height=600");
    } 
        
</SCRIPT>
<?php
echo "<div class='form'>";
echo "<h2> Payment Slip </h2>";
echo "<hr color='#2A7EF7'>";

    //echo "<div style='margin:10px 10px 10px 120px;padding:5px;border-top:2px solid #eee;border-left:2px solid #eee;border-right:3px solid #ccc;border-bottom:3px solid #ccc; width:250px; height:100px '>";
    //echo $html->link($html->image('../'.$this->data['Job']['image'], array('class' => 'adv')), $this->data['Adv']['link'], array(), false, false);
    //echo "</div>";
      
    //echo ":. Job Position : ".$html->link("<b>".$this->data['Job']['position']."</b>",array('controller'=>'jobs','action'=>'view',$this->data['Job']['id']), array(), false, false);  
    echo ":. Job Position : ";
    echo "<a href='javascript:open_win(".$this->data['Job']['id'].")' class='sky'>".$this->data['Job']['position']."</a>";
            
    echo "<div class='kotak2'>";
    echo $form->create('Job',array('action'=>'payment','type'=>'file','onsubmit'=>'return validation();'));
            echo $form->input('id');
            echo "<div class='input'><label>&nbsp</label> &nbsp";
            if($this->data['Job']['slip']!='')
            {
                echo $html->image('../'.$this->data['Job']['slip'], array('alt' => 'Your File is Missing','class'=>'slip'));
            }
            echo "</div>";
            
            echo $form->input('slip',array('type'=>'file','label'=>'Payment Slip'));
            echo "<div class='input'><label>".$html->link('[ Back ]',array('controller'=>'jobs','action'=>'my_jobs'))."</label><input type='submit' value='Submit'></div>";
    echo "</form>";   
    echo "</div>"; 
    echo ":. Please provide  <span class='red'>Image (.jpg or .jpeg or .gif or .png) </span> file";
echo "</div>";        
        
?>